package com.uplooking.proxy;

import org.aopalliance.intercept.MethodInterceptor;
import org.aopalliance.intercept.MethodInvocation;
import org.springframework.stereotype.Component;

@Component("HrAdv")
public class HrAdv  implements MethodInterceptor{

	@Override
	public Object invoke(MethodInvocation arg0) throws Throwable {
		//执行原由逻辑前
		System.out.println("环绕通知执行前");
		//执行原有逻辑
		Object result=arg0.proceed();
		
		//执行原由逻辑后
		System.out.println("环绕通知执行后");
		
		return result;
	}

}
